package com.code.generator.code.impl;

import com.code.config.DataSourceInfo;
import com.code.generator.context.velocity.VelocityGeneratorContext;

import java.io.File;

public class TesterGenerator extends AbstractVelocityGenerator {

    private static final String PACKAGE_TEST = "." + File.separator + ".." + File.separator + "test";

    @Override
    protected String getTemplateName(VelocityGeneratorContext context) {
        return DataSourceInfo.DRIVER_CLASS.getValue() + "/Tester.vm";
    }

    @Override
    protected String getPackageName(VelocityGeneratorContext context) {
        return context.get("packageService").toString();
    }

    @Override
    protected String getFileName(VelocityGeneratorContext context) {
        return context.get("entity").toString() + "ServiceTest.java";
    }

}
